package com.ruoyi.system.service.impl;

import java.util.List;

import com.ruoyi.common.core.domain.entity.BcertInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.BcertInfoMapper;
import com.ruoyi.system.service.IBcertInfoService;

/**
 * 根证书Service业务层处理
 * 
 * @author ess
 * @date 2021-10-18
 */
@Service
public class BcertInfoServiceImpl implements IBcertInfoService 
{
    @Autowired
    private BcertInfoMapper bcertInfoMapper;

    /**
     * 查询根证书
     * 
     * @param bcertId 根证书主键
     * @return 根证书
     */
    @Override
    public BcertInfo selectBcertInfoByBcertId(String bcertId)
    {
        return bcertInfoMapper.selectBcertInfoByBcertId(bcertId);
    }

    /**
     * 查询根证书列表
     * 
     * @param bcertInfo 根证书
     * @return 根证书
     */
    @Override
    public List<BcertInfo> selectBcertInfoList(BcertInfo bcertInfo)
    {
        return bcertInfoMapper.selectBcertInfoList(bcertInfo);
    }

    /**
     * 新增根证书
     * 
     * @param bcertInfo 根证书
     * @return 结果
     */
    @Override
    public int insertBcertInfo(BcertInfo bcertInfo)
    {
        return bcertInfoMapper.insertBcertInfo(bcertInfo);
    }

    /**
     * 修改根证书
     * 
     * @param bcertInfo 根证书
     * @return 结果
     */
    @Override
    public int updateBcertInfo(BcertInfo bcertInfo)
    {
        return bcertInfoMapper.updateBcertInfo(bcertInfo);
    }

    /**
     * 批量删除根证书
     * 
     * @param bcertIds 需要删除的根证书主键
     * @return 结果
     */
    @Override
    public int deleteBcertInfoByBcertIds(String[] bcertIds)
    {
        return bcertInfoMapper.deleteBcertInfoByBcertIds(bcertIds);
    }

    /**
     * 删除根证书信息
     * 
     * @param bcertId 根证书主键
     * @return 结果
     */
    @Override
    public int deleteBcertInfoByBcertId(String bcertId)
    {
        return bcertInfoMapper.deleteBcertInfoByBcertId(bcertId);
    }
}
